#include "PersonalComboWnd.h"

BOOL PersonalComboWnd::OnInitDialog(){
    if (!CMzWndEx::OnInitDialog()){
        return FALSE;
    }

    int y = 0;
    m_Caption.SetPos(0, y, GetWidth(), MZM_HEIGHT_CAPTION);
    m_Caption.SetID(SM_IDC_CAPTION_COMBO);
    m_Caption.SetText(SM_TEXT_CAPTION_COMBO);
    AddUiWin(&m_Caption);

    y += MZM_HEIGHT_CAPTION;
    m_Btn_Local_Combo.SetPos(0, y, GetWidth(), MZM_HEIGHT_BUTTONEX);
    m_Btn_Local_Combo.SetID(SM_IDC_BTN_LOCAL_COMBO);
    m_Btn_Local_Combo.SetText(SM_TEXT_BTN_LOCAL_COMBO);
    AddUiWin(&m_Btn_Local_Combo);

    y += MZM_HEIGHT_BUTTONEX;
    m_Btn_Country_Combo.SetPos(0, y, GetWidth(), MZM_HEIGHT_BUTTONEX);
    m_Btn_Country_Combo.SetID(SM_IDC_BTN_COUNTRY_COMBO);
    m_Btn_Country_Combo.SetText(SM_TEXT_BTN_COUNTRY_COMBO);
    AddUiWin(&m_Btn_Country_Combo);

    m_Toolbar.SetPos(0, GetHeight()-MZM_HEIGHT_TEXT_TOOLBAR,GetWidth(), MZM_HEIGHT_TEXT_TOOLBAR);
    m_Toolbar.SetID(SM_IDC_TOOLBAR_COMBO);
    m_Toolbar.SetButton(0, true, true, SM_TEXT_TOOLBAR_CANCEL);
    m_Toolbar.SetButton(2, true, true, SM_TEXT_TOOLBAR_OK);
    AddUiWin(&m_Toolbar);

    return TRUE;

};

void PersonalComboWnd::OnMzCommand(WPARAM wParam, LPARAM lParam){
    return EndModal(ID_CANCEL);
};

MZ_IMPLEMENT_DYNAMIC(PersonalComboWnd);